<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>
<script type="text/javascript" src="<%=basePath %>js/jquery-1.9.1.min.js"></script>
<link rel="stylesheet" href="<%=basePath %>css/buttons.css" />
<link rel="stylesheet" href="<%=basePath %>css/bootstrap.css"/>
<script type="text/javascript" src="<%=basePath %>js/buttons.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<script type="text/javascript">
$(document).ready(function(){
	$("#exit").click(function(){
		location.href = "<%=basePath %>index.jsp";
	});
}); 
</script>
<script type="text/javascript">
function sel(fid){
	location.href = "<%=basePath %>badbooking/selBadbookinginfo?fid=" + fid;
}
</script>
<body>
		<center>
		<form action="<%=basePath %>userInfo/selAll?selNameOrCode="selNameOrCode.value,txt=txt.value" method="post" role="form">
			<table border="0" width="800">
				<tr>
					<td align="center">
						<BR />
						<select id="selNameOrCode" name="selNameOrCode" style="width:100px;height:30px;">
							<option value="姓名">姓名</option>
							<option value="证件号">证件号</option>
						</select>
						<INPUT type="text" size="30" id="txt" name="txt"/>
						<input type="submit" value=" 查  询 " class="button button-pill button-primary" style="width: 90px; height: 30px; font-size: 10px;"/>&nbsp;&nbsp;
						<input type="button" value=" 返  回 " class="button button-pill button-primary" style="width: 90px; height: 30px; font-size: 10px;" id="exit"/>
					</td>
				</tr>
			</table>
			<table border="0"  class="table table-hover" align="center" style="width: 600px;" >
				<tr>
					<BR />
					<td>姓名</td><td>证件号</td><td></td><td></td>
					<c:forEach items="${userList }" var="user">
						<tr>
							<td>${user.fusername }</td>
							<td>${user.fcertificateno }</td>
							<td></td>
							<td>
								<input type="button" value="查看违规记录" id="update" class="button button-pill button-primary"
										style="width: 120px; height: 30px; font-size: 10px;" onclick="sel('${user.fid}')"/>
							</td>
						</tr>
					</c:forEach>
				</tr>	
			</table>
		</form>
	</center>
</body>
</html>